import request from '@/utils/request'

// 上传出库单
export function uploadOrderFileAPI(data) {
  return request({
    url: 'api/fileUpload/importOutboundInfo',
    method: 'post',
    data,
    headers: {
      'Content-Type': 'multipart/form-data'
    }
  })
}

// 上传库存信息
export function uploadStorageFileAPI(data) {
  return request({
    url: 'api/fileUpload/importInventoryInfo',
    method: 'post',
    data,
    headers: {
      'Content-Type': 'multipart/form-data'
    }
  })
}

export function downloadOutboundAPI(data) {
  return request({
    url: 'api/fileUpload/downloadCloseOutboundTemplate',
    method: 'post',
    responseType: 'blob',
    data
  })
}

export function downloadStorageAPI(data) {
  return request({
    url: 'api/fileUpload/downloadInventoryTemplate',
    method: 'post',
    responseType: 'blob',
    data
  })
}
